package com.gzsxy.excel.service.impl;

import com.gzsxy.excel.entity.FeedbackExportVo;
import com.gzsxy.excel.service.FeedbackService;
import org.springframework.stereotype.Service;

import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * @Description: TODO
 * @Author: xiaolong
 * @date: 2022/4/8 16:46
 * @Version: 1.0
 */
@Service
public class FeedbackServiceImpl implements FeedbackService {

    private static final SimpleDateFormat DATE_FORMAT = new SimpleDateFormat("yyyyMMddHHmmss");


    @Override
    public List<FeedbackExportVo> getFeedbackByParams(Map<String, Object> queryParams) {

        ArrayList<FeedbackExportVo> list = new ArrayList<>();

        for (int i = 0; i < 100; i++) {
            FeedbackExportVo feedbackExportVo = new FeedbackExportVo();
            feedbackExportVo.setDesc("测试测试");
            feedbackExportVo.setName("张晓龙");
            feedbackExportVo.setTel("19928354535");
            feedbackExportVo.setStatus("0");
            feedbackExportVo.setInsertTime(DATE_FORMAT.format(new Date()));
            feedbackExportVo.setUpdateTime(DATE_FORMAT.format(new Date()));
            list.add(feedbackExportVo);
        }
        return list;
    }
}
